package org.dromara.tearoom.service;

import org.dromara.tearoom.mqtt.BreakerDataRequest;
import org.eclipse.paho.client.mqttv3.MqttMessage;

/**
 * 断路器 下发命令
 * @author CKJ
 * @description: 断路器 下发命令
 * @date 2025/4/15 18:18
 */
public interface IBreakerCommandService {

    //下发命令 定时任务自动执行的命令
    boolean commandBreaker(BreakerDataRequest breakerDataRequest, boolean isAuto, boolean isLog);

    //下发命令 手动执行
    boolean commandBreaker(BreakerDataRequest breakerDataRequest, boolean isLog);

    //批量下达命令 手动执行
    boolean commandBreakerBatch(BreakerDataRequest breakerDataRequest);

    //给网关下发上报时间
    boolean commandGatewayTimeReporting(String gatewayCode, int minute);

    //断路器回调
    void breakerCallback(String topic, MqttMessage mqttMessage);

}
